package com.ben.controller;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

@Controller
public class EncodingController {
    @RequestMapping("/e/t")
    public String test(@RequestParam("username") String username, Model model) {
        model.addAttribute("msg", username); //获取表单提交的值
        return "hello"; //跳转到test页面显示输入的值
    }
}
